{% extends 'ApiCloud/Base/layout.common.html.twig' %}

{% block body %}
    <div class=" pad5 ">
        <div class="round5" style="height: 30vw">
            <mu-carousel class="round5" style="height: 30vw">
                <mu-carousel-item class="round5" v-for="item in banner">
                     <img class="round5" style="width: 100vw;height: 30vw" :src="picUrl(item.pic)" onerror="this.src=pic404" @click="goto('articlesInfo',{id:item.action})" v-if="isTrue(item.action)">
                     <img class="round5" style="width: 100vw;height: 30vw" :src="picUrl(item.pic)" onerror="this.src=pic404" v-if="!isTrue(item.action)">

{#                    <img class="round5" style="width: 100vw;height: 30vw" :src="picUrl(item.pic)" onerror="this.src=pic404" v-if="!isTrue(item.action)">#}
{#                    <img class="round5" style="width: 100vw;height: 30vw" :src="picUrl(item.pic)" onerror="this.src=pic404" @click="goto('articlesInfo',{id:item.action})" v-if="isTrue(item.action)">#}
                </mu-carousel-item>
            </mu-carousel>
        </div>
        <div class="padt5" v-if="isTrue(announce) && announce.length>0">
            <mu-carousel hide-indicators hide-controls  style="height: 8vw" interval="3333">
                <mu-carousel-item  v-for="item,index in announce[0]">
                    <div class="flrc fs8 pad3 bc13 round30">
                        <div class="flex1"> [[item.text]] </div>
                        {#                        <div class="c2  pos-r" @click="tabTo(3)">我要发布</div>#}
                        <div class="">[[timePass(item.createAt)]]前</div>
                    </div>
                </mu-carousel-item>
            </mu-carousel>
        </div>
    </div>
    <div class="flrc bc0">
        <div class="flex1">
            <mu-tabs @change="tab" :value.sync="curTab" inverse :color="c1" text-color="rgba(0, 0, 0, .54)" full-width>
                <mu-tab><span class="fs8">待报价</span></mu-tab>
                <mu-tab><span class="fs8">已报价</span></mu-tab>
                <mu-tab><span class="fs8">待办</span></mu-tab>
                <mu-tab><span class="fs8">错过订单</span></mu-tab>
                <mu-tab><span class="fs8">报价记录</span></mu-tab>
            </mu-tabs>
        </div>
    </div>

    <div class="">

        {#            1.没有登录无法发布#}
        {#            2.没有实名认证的用户无法发布#}
        {#            3.没有开通店铺跳转开通#}
        {#            4.需要设置行业才能匹配#}

        <div class="pad20" v-if="status.login == 0">
            <mu-button @click="goto('login')" round full-width large>请先登录</mu-button>
        </div>
        <div class="pad20" v-if="status.login == 1 && status.mendian == 0">
            <mu-button @click="openShop('')" round full-width large>开通店铺</mu-button>
        </div>
        <div class="c12 fs8 pad20" v-if="status.login == 1 && status.mendian == 1 && (status.shiming == 0 || status.weizhi == 0 || status.hangye == 0)">
            <div class=" bcf pad5" v-if="status.shiming == 0">
                <div class="flrc pos-r pad10 bdbda">
                    <div class="c02"><span class="fa fa-warning"></span></div>
                    <mu-ripple @click="goto('myAuth')" class="flex1 padl10">请完成实名认证（需审核）</mu-ripple>
                    <span class="fa fa-angle-right c12"></span>
                </div>
            </div>
            <div class=" bcf pad5" v-if="status.weizhi == 0">
                <div class="flrc pos-r pad10 bdbda">
                    <div class="c02"><span class="fa fa-warning"></span></div>
                    <mu-ripple @click="goto('shopInfo')" class="flex1 padl10">请设置您的店铺信息</mu-ripple>
                    <span class="fa fa-angle-right c12"></span>
                </div>
            </div>
            <div class=" bcf pad5" v-if="status.hangye == 0">
                <div class="flrc pos-r pad10 bdbda">
                    <div class="c02"><span class="fa fa-warning"></span></div>
                    <mu-ripple @click="goto('shopCat')" class="flex1 padl10">请选择所在行业（需审核）</mu-ripple>
                    <span class="fa fa-angle-right c12"></span>
                </div>
            </div>
        </div>
    </div>
    <div v-show="status.login == 1 && status.mendian == 1 && status.shiming == 1 && status.weizhi == 1 && status.hangye == 1">
        <div class="pad5" v-if="curTab == 0">
            <div class="pos-r" v-for="item in list">
                {% include "ApiCloud/Base/inc.task.list.shop.html.twig" with {from:"0"} %}
                <mu-ripple @click="goto('taskInfo',{id:item.task.id})"></mu-ripple>
            </div>
        </div>
        <div class="pad5" v-if="curTab == 1">
            <div class="pos-r" v-for="item in listVote">
                {% include "ApiCloud/Base/inc.task.list.shop.html.twig" with {from:"1"} %}
                <mu-ripple @click="goto('taskInfo',{id:item.task.id})"></mu-ripple>
            </div>
        </div>
        <div class="pad5" v-if="curTab == 2">
            <div class="pos-r" v-for="item in listHire">
                {% include "ApiCloud/Base/inc.task.list.shop.html.twig" with {from:"2"} %}
                <mu-ripple @click="goto('taskInfo',{id:item.task.id})"></mu-ripple>
            </div>
        </div>
        <div class="pad5" v-if="curTab == 3">
            <div class="pos-r" v-for="item in listDone">
                {% include "ApiCloud/Base/inc.task.list.shop.html.twig" with {from:"3"} %}
                <div class="flrc padl5 padr5 padb5 bdbda fs8 tar">
                    <div class="flex1 c11 op7">成交价格：</div>
                    <div class="c2 fwb">[[item.price]]</div>
                </div>
                <mu-ripple @click="goto('taskInfo',{id:item.task.id})"></mu-ripple>
            </div>
        </div>
        <div class="pad5" v-if="curTab == 4">
            <div class="pos-r bdbso" v-for="item in listLog">
                {% include "ApiCloud/Base/inc.task.list.shop.html.twig" with {from:"4"} %}
                <mu-ripple @click="goto('taskInfo',{id:item.task.id})"></mu-ripple>
                <div class="flrc fs8 padlr5 padb10">
                    <div>我的报价：</div>
                    <div class="flex1 c2 fwb fs10 tar">[[item.price]]</div>
                </div>
            </div>
        </div>
    </div>



{% endblock %}
